<!DOCTYPE HTML>
<html xmlns:wb="http://open.weibo.com/wb">
	<head>
		</script>
		<script src="style/js/allmobilize.min.js" charset="utf-8" id="allmobilize"></script>
		<style type="text/css"></style>
		<meta content="no-siteapp" http-equiv="Cache-Control">
		<link media="handheld" rel="alternate">
		<!-- end 云适配 -->
		<meta content="text/html; charset=utf-8" http-equiv="Content-Type">
		<title>编辑兼职信息-招聘服务-东莞大学生兼职网站-最专业的企业端招聘平台</title>
		<meta content="23635710066417756375" property="qc:admins">

		<!-- <div class="web_root"  style="display:none">http://www.lagou.com</div> -->
		<script type="text/javascript">
			var ctx = "http://www.lagou.com";
			console.log(1);
		</script>
		<link href="http://www.lagou.com/images/favicon.ico" rel="Shortcut Icon">
		<link href="style/css/style.css" type="text/css" rel="stylesheet">
		<link href="style/css/external.min.css" type="text/css" rel="stylesheet">
		<link href="style/css/popup.css" type="text/css" rel="stylesheet">
		<script type="text/javascript" src="style/js/jquery.1.10.1.min.js"></script>
		<script src="style/js/jquery.lib.min.js" type="text/javascript"></script>
		<script type="text/javascript" src="style/js/ajaxfileupload.js"></script>
		<script src="style/js/additional-methods.js" type="text/javascript"></script>
		<script src="style/js/info.js" type="text/javascript"></script>
		<script type="text/javascript" src="style/js/neturl.js"></script>
		<script src="style/js/getUrlParam.js" type="text/javascript"></script>
		<!--[if lte IE 8]>
    <script type="text/javascript" src="style/js/excanvas.js"></script>
<![endif]-->
		<script src="style/js/ajaxCross.json" charset="UTF-8"></script>
		<style type="text/css">
			select {
				width: 100%;
				height: 100%;
				background-color: #f54545;
				color: white;
				/* 去掉三角 */
				appearance: none;
				-moz-appearance: none;
				/* Firefox */
				-webkit-appearance: none;
				/* Safari 和 Chrome */
			}
		</style>
		<link rel="stylesheet" href="style/css/ui.css">
		<link rel="stylesheet" href="style/css/window.css">
	</head>
	<body>
		<div id="body">
			<div id="header">
				<div class="wrapper">
					<a href="index.html" class="logo" >
						<img src="style/images/logo.png" width="200" height="50" alt="东莞大学生兼职网站企业端" />
					</a>
					<ul id="navheader" class="reset">
						<li><a href="index.html">首页</a></li>
						<li><a href="myhome.html">我的公司</a></li>
						<li><a href="mList.html">我的职位</a></li>
						<li><a rel="nofollow" href="canInterviewResumes.html">应聘我的</a></li>
						<li class="current"><a rel="nofollow" href="create.html">发布职位</a></li>
					</ul>
					<dl class="collapsible_menu">
						<dt>
							
							<span><span id="uname"></span>&nbsp;</span>
							<span class="red dn" id="noticeDot-1"></span>
							<i></i>
						</dt>
						<dd><a href="mList.html">我发布的职位</a></dd>
						<dd><a href="canInterviewResumes.html">我收到的简历</a></dd>
						<dd class="btm"><a href="myhome.html">我的公司主页</a></dd>
						<dd class="logout" id="logout"><a rel="nofollow">退出</a></dd>
					</dl>
				</div>
			</div><!-- end #header -->
			<div id="container">
				<div style="width: 100%;">
					<dl class="company_center_content">
						<dt>
							<h1>
								<em></em>
								发布新兼职
							</h1>
						</dt>
						<dd>
							<div class="ccc_tr">为了更好的找到您<span>心仪</span> 的员工，请您 <span>准确真实</span> 的填写职位信息</div>
							<form action="http://www.lagou.com/corpPosition/preview.html" method="post" id="jobForm">
								<input type="hidden" value="" name="id">
								<input type="hidden" value="create" name="preview">
								<input type="hidden" value="25927" name="companyId">
								<input type="hidden" value="c29d4a7c35314180bf3be5eb3f00048f" name="resubmitToken">
								<table class="btm">
									<tbody>
										<tr>
											<td width="25"><span class="redstar">*</span></td>
											<td>兼职名称</td>
											<td>
												<input type="text" placeholder="请输入兼职名称，如：产品经理" value="" name="positionName" id="positionName">
											</td>
										</tr>
										<tr>
											<td width="25"><span class="redstar">*</span></td>
											<td>兼职行业</td>
											<td>
												<select name="Profession" id="Profession" class="selectr selectr_380">
													<script type="profession_html/html" id="profession_tem">
														{{each profession_json.records}}
															<option value="{{$value.id}}">{{$value.name}}</option>
														{{/each}}
													</script>
												</select>
											</td>
										</tr>
										<tr>
											<td width="25"><span class="redstar">*</span></td>
											<td>招聘人数</td>
											<td>
												<input type="number" placeholder="请输入招聘人数" value="" name="employnum" id="employnum">
											</td>
										</tr>
									</tbody>
								</table>

								<table class="btm">
									<tbody>
										<tr>
											<td width="25"><span class="redstar">*</span></td>
											<td>月薪范围</td>
											<!--<h3><span>(最高月薪不能大于最低月薪的2倍)</span></h3> -->
											<td>
												<div class="salary_range">
													<div>
														<input type="number" placeholder="最低月薪" value="" id="MinMoney" name="MinMoney">
														<span>￥</span>
													</div>
													<div>
														<input type="number" placeholder="最高月薪" value="" id="MaxMoney" name="MaxMoney">
														<span>￥</span>
													</div>
													<span>只能输入整数，如：9</span>
												</div>
											</td>
										</tr>
										<tr>
											<td width="25"><span class="redstar">*</span></td>
											<td>工作城市</td>
											<td>
												<select name="provincem" id="provincem" class="selectr selectr_250">
													<option value="">省份</option>
													<!-- 利用js把省份添加到下拉列表里-->
													<script type="text/javascript">
														for (var i = 0; i < provinceArr.length; i++) {
															document.write("<option value='" + i + "'>" + provinceArr[i] + "</option>");

														}
													</script>
												</select>
												<select name="city" id="city" class="selectr selectr_300">
													<option value="">城市</option>
												</select>
											</td>
										</tr>
										<tr>
											<td width="25"><span class="redstar">*</span></td>
											<td>开始日期</td>
											<td>
												<input type="date" value="2020-04-08" id="startdate" name="startdate" class="selectr_330">
											</td>
										</tr>
										<tr>
											<td width="25"><span class="redstar">*</span></td>
											<td>结束日期</td>
											<td>
												<input type="date" value="2020-04-08" id="enddate" name="enddate" class="selectr_330">
											</td>
										</tr>
									</tbody>
								</table>

								<table class="btm">
									<tbody>
										<tr>
											<td width="25"><span class="redstar">*</span></td>
											<td>学历要求</td>
											<!--<h3><span>(最高月薪不能大于最低月薪的2倍)</span></h3> -->
											<td>
												<input type="hidden" id="education" value="" name="education">
												<input type="button" value="请选择学历要求" id="select_education" class="selectr selectr_380">
												<div class="boxUpDown boxUpDown_380 dn" id="box_education" style="display: none;">
													<ul>
														<li>
															不限
														</li>
														<li>
															大专在读
														</li>
														<li>
															大专毕业
														</li>
														<li>
															本科在读
														</li>
														<li>
															本科毕业
														</li>
													</ul>
												</div>
											</td>
										</tr>
									</tbody>
								</table>

								<table class="btm">
									<tbody>
										<tr>
											<td width="25"><span class="redstar">*</span></td>
											<td width="85">职位要求</td>
											<td>
												<span class="c9 f14">(建议分条描述对应聘者的技能、性格、性别等要求等。)</span>
												<textarea name="JobRequire" id="JobRequire" class="tinymce" aria-hidden="true"></textarea>
											</td>
										</tr>
										<tr>
											<td><span class="redstar">*</span></td>
											<td>工作内容</td>
											<td>
												<span class="c9 f14">(建议分条描述工作职责等。请勿输入公司邮箱、联系电话及其他外链。)</span>
												<textarea name="positionDetail" id="positionDetail" class="tinymce" aria-hidden="true"></textarea>
											</td>
										</tr>
										<tr>
											<td><span class="redstar">*</span></td>
											<td>工作地址</td>
											<td>
												<input type="text" placeholder="请输入详细的工作地址" value="" name="positionAddress" class="input_520" id="positionAddress">
												<input type="hidden" value="" name="positionLng" id="lng">
												<input type="hidden" value="" name="positionLat" id="lat">
												<div class="work_place f14">我们将在职位详情页以地图方式精准呈现给用户 <a id="mapPreview" href="javascript:;">预览地图</a></div>
											</td>
										</tr>
									</tbody>
								</table>

								<table>
									<tbody>
										<tr>
											<td width="25"><span class="redstar">*</span></td>
											<td colspan="2">
												接收简历邮箱： <span id="receiveEmailVal">admin@admin.com</span>
												<input type="hidden" value="admin@admin.com" id="receiveEmail" name="email">
											</td>
										</tr>
										<tr>
											<td><span class="redstar">*</span></td>
											<td>联系人：</td>
											<td>
												<input type="text" placeholder="请输入联系人" value="" name="Contact" id="Contact">
											</td>
										</tr>
										<tr>
											<td><span class="redstar">*</span></td>
											<td>联系方式：</td>
											<td>
												<input type="tel" placeholder="请输入联系方式，如：手机号码" value="" name="phone" id="phone">
											</td>
										</tr>
										<tr>
											<td width="25"></td>
											<td colspan="2">
												<input type="button" value="更新" id="submit_job" class="btn_32">
											</td>
										</tr>
									</tbody>
								</table>
							</form>
						</dd>
					</dl>
				</div><!-- end .content -->

				<!------------------------------------- 弹窗lightbox ----------------------------------------->
				<div style="display:none;">
					<!--联系方式弹窗-->
					<div style="height:180px;" class="popup" id="telTip">
						<form id="telForm">
							<table width="100%">
								<tbody>
									<tr>
										<td align="center" class="f18">留个联系方式方便我们联系你吧！</td>
									</tr>
									<tr>
										<td align="center">
											<input type="text" maxlength="49" placeholder="请输入你的手机号码或座机号码" name="tel">
											<span style="display:none;" class="error" id="telError"></span>
										</td>
									</tr>
									<tr>
										<td align="center">
											<input type="submit" value="提交" class="btn">
										</td>
									</tr>
								</tbody>
							</table>
						</form>
					</div>
					<!--/#telTip-->

					<!--地图弹窗-->
					<div class="popup" id="baiduMap">
						<div class="mb10">点击地图可重新定位公司所在的位置</div>
						<div id="allmap" style="overflow: hidden; position: relative; z-index: 0; background-color: rgb(243, 241, 236); color: rgb(0, 0, 0); text-align: left;">
							<div style="overflow: visible; position: absolute; z-index: 0; left: 0px; top: 0px; cursor: grab;">
								<div class="BMap_mask" style="position: absolute; left: 0px; top: 0px; z-index: 9; overflow: hidden; width: 0px; height: 0px;"></div>
								<div style="position: absolute; height: 0px; width: 0px; left: 0px; top: 0px; z-index: 200;">
									<div style="position: absolute; height: 0px; width: 0px; left: 0px; top: 0px; z-index: 800;"></div>
									<div style="position: absolute; height: 0px; width: 0px; left: 0px; top: 0px; z-index: 700;"></div>
									<div style="position: absolute; height: 0px; width: 0px; left: 0px; top: 0px; z-index: 600;"></div>
									<div style="position: absolute; height: 0px; width: 0px; left: 0px; top: 0px; z-index: 500;"><label class="BMapLabel"
										 unselectable="on" style="position: absolute; -moz-user-select: none; display: none; cursor: inherit; background-color: rgb(190, 190, 190); border: 1px solid rgb(190, 190, 190); padding: 1px; white-space: nowrap; font: 12px arial,simsun,sans-serif; z-index: -20000; color: rgb(190, 190, 190);">shadow</label></div>
									<div style="position: absolute; height: 0px; width: 0px; left: 0px; top: 0px; z-index: 400;"></div>
									<div style="position: absolute; height: 0px; width: 0px; left: 0px; top: 0px; z-index: 300;"></div>
									<div style="position: absolute; height: 0px; width: 0px; left: 0px; top: 0px; z-index: 201;"></div>
									<div style="position: absolute; height: 0px; width: 0px; left: 0px; top: 0px; z-index: 200;"></div>
								</div>
								<div style="position: absolute; overflow: visible; top: 0px; left: 0px; z-index: 1;">
									<div style="position: absolute; overflow: visible; z-index: -100; left: 0px; top: 0px; display: none;"></div>
								</div>
								<div style="position: absolute; overflow: visible; top: 0px; left: 0px; z-index: 2; display: block;">
									<div style="position: absolute; overflow: visible; top: 0px; left: 0px; z-index: 0; display: block;"><canvas
										 style="position: absolute; width: 256px; height: 256px; left: -74px; top: -213px; background: none repeat scroll 0% 0% rgb(243, 241, 236);"
										 width="256" height="256" id="_1_bg_6323_2355_15"></canvas></div>
									<div style="position: absolute; overflow: visible; top: 0px; left: 0px; z-index: 10; display: block;"><canvas
										 style="position: absolute; width: 256px; height: 256px; left: -74px; top: -213px;" width="256" height="256"
										 id="_1_poi_6323_2355_15"></canvas></div>
								</div>
								<div style="position: absolute; overflow: visible; top: 0px; left: 0px; z-index: 3;"></div>
							</div>
							<div style="position: absolute; z-index: 1201; top: 10px; right: 10px; width: 17px; height: 16px; background: url(style/images/img/st-close.pngquot) no-repeat scroll 0% 0% transparent; cursor: pointer; display: none;"
							 title="退出全景"></div>
							<div style="height: 32px; position: absolute; z-index: 30; -moz-user-select: none; bottom: 0px; right: auto; top: auto; left: 1px; display: none;"
							 class=" anchorBL"><a title="到百度地图查看此区域" target="_blank" href="http://map.baidu.com/?sr=1" style="outline: medium none;"><img
									 src="style/images/copyright_logo.png" style="border:none;width:77px;height:32px"></a></div>
							<div style="position:absolute;z-index:0;top:0px;left:0px;overflow:hidden;visibility:hidden;cursor:-moz-grab" id="zoomer">
								<div style="top:0;left:0;" class="BMap_zoomer"></div>
								<div style="top:0;right:0;" class="BMap_zoomer"></div>
								<div style="bottom:0;left:0;" class="BMap_zoomer"></div>
								<div style="bottom:0;right:0;" class="BMap_zoomer"></div>
							</div>
							<div unselectable="on" class=" BMap_stdMpCtrl BMap_stdMpType0 BMap_noprint anchorTL" style="width: 62px; height: 186px; bottom: auto; right: auto; top: 10px; left: 10px; position: absolute; z-index: 1100; -moz-user-select: none;">
								<div class="BMap_stdMpPan">
									<div title="向上平移" class="BMap_button BMap_panN"></div>
									<div title="向左平移" class="BMap_button BMap_panW"></div>
									<div title="向右平移" class="BMap_button BMap_panE"></div>
									<div title="向下平移" class="BMap_button BMap_panS"></div>
									<div class="BMap_stdMpPanBg BMap_smcbg"></div>
								</div>
								<div class="BMap_stdMpZoom" style="height: 141px; width: 62px;">
									<div title="放大一级" class="BMap_button BMap_stdMpZoomIn">
										<div class="BMap_smcbg"></div>
									</div>
									<div title="缩小一级" class="BMap_button BMap_stdMpZoomOut" style="top: 120px;">
										<div class="BMap_smcbg"></div>
									</div>
									<div class="BMap_stdMpSlider" style="height: 102px;">
										<div class="BMap_stdMpSliderBgTop" style="height: 102px;">
											<div class="BMap_smcbg"></div>
										</div>
										<div class="BMap_stdMpSliderBgBot" style="top: 19px; height: 87px;"></div>
										<div title="放置到此级别" class="BMap_stdMpSliderMask"></div>
										<div title="拖动缩放" class="BMap_stdMpSliderBar" style="cursor: grab; top: 19px;">
											<div class="BMap_smcbg"></div>
										</div>
									</div>
									<div class="BMap_zlHolder">
										<div class="BMap_zlSt">
											<div class="BMap_smcbg"></div>
										</div>
										<div class="BMap_zlCity">
											<div class="BMap_smcbg"></div>
										</div>
										<div class="BMap_zlProv">
											<div class="BMap_smcbg"></div>
										</div>
										<div class="BMap_zlCountry">
											<div class="BMap_smcbg"></div>
										</div>
									</div>
								</div>
							</div>
							<div unselectable="on" style="bottom: auto; right: 10px; top: 10px; left: auto; white-space: nowrap; cursor: pointer; position: absolute; z-index: 10; -moz-user-select: none;"
							 class=" BMap_noprint anchorTR">
								<div style="-moz-user-select: none; float: left;">
									<div style="-moz-user-select: none; box-shadow: 2px 2px 3px rgba(0, 0, 0, 0.35); border-left: 1px solid rgb(139, 164, 220); border-top: 1px solid rgb(139, 164, 220); border-bottom: 1px solid rgb(139, 164, 220); background: none repeat scroll 0% 0% rgb(142, 168, 224); padding: 2px 6px; font: bold 12px/1.3em arial,simsun,sans-serif; text-align: center; white-space: nowrap; border-radius: 3px 0px 0px 3px; color: rgb(255, 255, 255);"
									 title="显示普通地图">地图</div>
								</div>
								<div style="-moz-user-select: none; float: left;">
									<div style="-moz-user-select: none; box-shadow: 2px 2px 3px rgba(0, 0, 0, 0.35); border-left: 1px solid rgb(139, 164, 220); border-top: 1px solid rgb(139, 164, 220); border-bottom: 1px solid rgb(139, 164, 220); background: none repeat scroll 0% 0% rgb(255, 255, 255); padding: 2px 6px; font-family: arial,simsun,sans-serif; font-style: normal; font-variant: normal; font-size: 12px; line-height: 1.3em; font-size-adjust: none; font-stretch: normal; -moz-font-feature-settings: normal; -moz-font-language-override: normal; text-align: center; white-space: nowrap; color: rgb(0, 0, 0);"
									 title="显示卫星影像">卫星</div>
									<div style="-moz-user-select: none; position: absolute; top: 0px; left: 0px; z-index: -1; display: none;">
										<div style="border-right:1px solid #8ba4dc;border-bottom:1px solid #8ba4dc;border-left:1px solid #8ba4dc;background:white;font:12px arial,simsun,sans-serif;padding:0 8px 0 6px;line-height:1.6em;box-shadow:2px 2px 3px rgba(0, 0, 0, 0.35)"
										 title="显示带有街道的卫星影像"><span class="BMap_checkbox" "="" checked=" checked"></span><label style="vertical-align: middle; cursor: pointer;">混合</label></div>
									</div>
								</div>
								<div style="-moz-user-select: none; float: left;">
									<div style="-moz-user-select: none; box-shadow: 2px 2px 3px rgba(0, 0, 0, 0.35); border-left: 1px solid rgb(139, 164, 220); border-width: 1px; border-style: solid; border-color: rgb(139, 164, 220); background: none repeat scroll 0% 0% rgb(255, 255, 255); padding: 2px 6px; font-family: arial,simsun,sans-serif; font-style: normal; font-variant: normal; font-size: 12px; line-height: 1.3em; font-size-adjust: none; font-stretch: normal; -moz-font-feature-settings: normal; -moz-font-language-override: normal; text-align: center; white-space: nowrap; border-radius: 0px 3px 3px 0px; color: rgb(0, 0, 0);"
									 title="显示三维地图">三维</div>
								</div>
							</div>
							<div unselectable="on" class=" BMap_scaleCtrl BMap_noprint anchorBL" style="bottom: 18px; right: auto; top: auto; left: 81px; width: 88px; position: absolute; z-index: 10; -moz-user-select: none;">
								<div unselectable="on" class="BMap_scaleTxt" style="background-color: transparent; color: black;">500&nbsp;米</div>
								<div class="BMap_scaleBar BMap_scaleHBar" style="background-color: black;"><img src="style/images/mapctrls.png"
									 style="border:none"></div>
								<div class="BMap_scaleBar BMap_scaleLBar" style="background-color: black;"><img src="style/images/mapctrls.png"
									 style="border:none"></div>
								<div class="BMap_scaleBar BMap_scaleRBar" style="background-color: black;"><img src="style/images/mapctrls.png"
									 style="border:none"></div>
							</div>
							<div unselectable="on" class=" BMap_omCtrl BMap_ieundefined BMap_noprint anchorBR quad4" style="width: 13px; height: 13px; bottom: 0px; right: 0px; top: auto; left: auto; position: absolute; z-index: 10; -moz-user-select: none;">
								<div class="BMap_omOutFrame" style="width: 149px; height: 149px;">
									<div class="BMap_omInnFrame" style="bottom: auto; right: auto; top: 5px; left: 5px; width: 142px; height: 142px;">
										<div class="BMap_omMapContainer"></div>
										<div class="BMap_omViewMv" style="cursor: grab;">
											<div class="BMap_omViewInnFrame">
												<div></div>
											</div>
										</div>
									</div>
								</div>
								<div class="BMap_omBtn BMap_omBtnClosed" style="bottom: 0px; right: 0px; top: auto; left: auto;"></div>
							</div>
							<div unselectable="on" class=" BMap_cpyCtrl BMap_noprint anchorBL" style="cursor: default; white-space: nowrap; -moz-user-select: none; color: black; background: none repeat scroll 0% 0% transparent; font: 11px/15px arial,simsun,sans-serif; bottom: 2px; right: auto; top: auto; left: 4px; position: absolute; z-index: 10;"><span
								 _cid="1" style="display: inline;"><span style="font-size:11px">&copy; 2014 Baidu&nbsp;- Data &copy; <a style="display:inline;"
										 href="http://www.navinfo.com/" target="_blank">NavInfo</a> &amp; <a style="display:inline;" href="http://www.cennavi.com.cn/"
										 target="_blank">CenNavi</a> &amp; <a style="display:inline;" href="http://www.365ditu.com/" target="_blank">道道通</a></span></span></div>
						</div>
					</div>
					<!--/#baiduMap-->
				</div>

				<script src="style/js/jquery.tinymce.js" type="text/javascript"></script>
				<script type="text/javascript" src="style/js/template-web.js"></script>
				<script src="style/js/jobs.min.js" type="text/javascript"></script>
				<script src="http://api.map.baidu.com/api?v=2.0&amp;ak=A2c1a1ff1fe0750e3290660295aac602" type="text/javascript"></script>
				<script src="http://api.map.baidu.com/getscript?v=2.0&amp;ak=A2c1a1ff1fe0750e3290660295aac602&amp;services=&amp;t=20140617153133"
				 type="text/javascript"></script>
				<script>
					var company_id = "";
					var job_id = "";
					var cemail = "";
					$(document).ready(function() {
						company_id = getCookie('company_id');
						if(company_id == ''){
							window.location.href = "login.html";
						}
						var uname = getCookie('uname');
						$('#uname').text(uname);
						job_id = UrlParm.parm("job_id");
						cemail = getCookie('cemail');
						$('#receiveEmailVal').text(cemail);
						getProfession();
						get_job_info();
					});
					//存cookie
					function setCookie(name, value) {
						var Days = 30;
						var exp = new Date();
						exp.setTime(exp.getTime() + Days * 24 * 60 * 60 * 1000);
						document.cookie = name + "=" + escape(value) + ";expires=" + exp.toGMTString();
					}
					$("#logout").click(function(){
						console.log("退出")
						setCookie('company_id','')
						setCookie('cname','')
						setCookie('cemail','')
						window.location.href = "login.html";
					});
					function getCookie(name) {
						var arr, reg = new RegExp("(^| )" + name + "=([^;]*)(;|$)");
						if (arr = document.cookie.match(reg))
							return unescape(arr[2]);
						else
							return null;
					}
					function getProfession() {
						$.ajax({ //传数据的方式
							url: ip_address + "/profession/list",
							type: "post",
							data: {
								pageSize: 500
							},
							success: function(result, textStatus, request) { //传数据成功之后的操作   result是servlet传过来的数据  这个函数对result进行处理，让它显示在 输入框中
								console.log('返回了' + JSON.stringify(result))
								var status = result.status;
								if (status == 0) {
									console.log('返回正确')
									var profession_data = result.data;
									var profession_html = template('profession_tem', {
										profession_json: profession_data
									})
									var Profession = document.querySelector('#Profession');
									Profession.innerHTML = profession_html;
								} else {
									var msg = result.msg;
									alert(msg)
								}
							},
							error: function(Error) {
								console.log(Error);
							},
							complete: function(xhr, data) {
								console.log("complete");
							}
						});
					}
					function get_job_info(){
						$.ajax({ //传数据的方式
							url: ip_address + "/job/info?id=" + job_id,
							type: "post",
							success: function(result, request) { //传数据成功之后的操作   result是servlet传过来的数据  这个函数对result进行处理，让它显示在 输入框中
								console.log('返回了' + JSON.stringify(result))
								var status = result.status;
								if (status == 0) {
									var data = result.data;
									var createTime = data.createTime;
									var cname = data.cname;
									var phone = data.phone;
									var professionName = data.professionName;
									var title = data.title;
									var maxMoney = data.maxMoney;
									var minMoney = data.minMoney;
									var workPlace = data.workPlace;
									var jobRequire = data.jobRequire;
									var jobDescribe = data.jobDescribe;
									var contact = data.contact;
									var education = data.education;
									var employNum = data.employNum;
									var email = data.email;
									
									$('#positionName').val(title);
									$('#employnum').val(employNum);
									$('#JobRequire').val(jobRequire);
									$('#positionDetail').val(jobDescribe);
									$('#MinMoney').val(minMoney);
									$('#MaxMoney').val(maxMoney);
									$('#Contact').val(contact);
									$('#phone').val(phone);
									$("#select_education").val(education); 
								} else {
									var msg = result.msg;
									alert(msg);
								}
							},
							error: function(Error) {
								console.log(Error);
							},
							complete: function(xhr, data) {
								console.log("complete");
							}
						});
					}
					$("#submit_job").click(function(){
					    	console.log('发布职位')
							var Title = $('#positionName').val();
							var EmployNum = $('#employnum').val();
							var JobRequire = $('#JobRequire').val();
							var JobDescribe =$('#positionDetail').val();
							var MinMoney = $('#MinMoney').val();
							var MaxMoney = $('#MaxMoney').val();
							var Contact = $('#Contact').val();
							var Phone = $('#phone').val();
							var coptions=$("#city option:selected"); //获取选中的项
							var WorkPlace = coptions.text(); //拿到选中项的文本
							var Education = $("#select_education").val(); 
							var poptions=$("#Profession option:selected"); //获取选中的项
							var ProfessionId = poptions.val(); //拿到选中项的值
							var starttime = $('#startdate').val();
							var endtime = $('#enddate').val();
							
							if(Title == ""){
								alert("兼职名称不能为空");
								return;
							}
							if(EmployNum == ""){
								alert("招聘人数不能为空");
								return;
							}
							if(EmployNum <= 0){
								alert("招聘人数不正确");
								return;
							}
							if(MinMoney == ""||MaxMoney == ""){
								alert("月薪范围不能为空");
								return;
							}
							if(MinMoney <= 0||MaxMoney <= 0||MaxMoney<=MinMoney){
								alert("月薪范围不正确");
								return;
							}
							if(WorkPlace == "城市"){
								alert("请选择工作地点");
								return;
							}
							if(Contact == ""){
								alert("联系人不能为空");
								return;
							}
							if(Phone == ""){
								alert("联系方式不能为空");
								return;
							}
							if(JobRequire == ""){
								alert("职位要求不能为空");
								return;
							}
							if(JobDescribe == ""){
								alert("职位描述不能为空");
								return;
							}
							if(Education == "请选择学历要求"){
								alert("请选择学历要求");
								return;
							}
							var isphone = checkPhone(Phone);
							if(isphone == false){
								alert("手机格式不正确");
								return;
							}
							var start = new Date(starttime.replace("-", "/").replace("-", "/"));
							var end = new Date(endtime.replace("-", "/").replace("-", "/"));
							if (end < start) {
							    alert('结束日期不能小于开始日期！');
							    return;
							}
							console.log('行业id'+ProfessionId)
							console.log(JobRequire);
							$.ajax({ //传数据的方式
								url: ip_address + "/job/update",
								type: "post",
								data:{
									id:job_id,
									CompanyId:company_id,
									Title:Title,
									ProfessionId:ProfessionId,
									EmployNum:EmployNum,
									JobRequire:JobRequire,
									JobDescribe:JobDescribe,
									MinMoney:MinMoney,
									MaxMoney:MaxMoney,
									Contact:Contact,
									Phone:Phone,
									WorkPlace:WorkPlace,
									Education:Education,
									startTime:starttime+" 00:00:00",
									endTime:endtime+" 00:00:00"
								},
								success: function(result, textStatus, request) { //传数据成功之后的操作   result是servlet传过来的数据  这个函数对result进行处理，让它显示在 输入框中
									console.log('返回了' + JSON.stringify(result))
									var status = result.status;
									if (status == 0) {
										console.log('返回正确')
										var data = result.data;
										window.location.href = "jobdetail.html?job_id="+job_id;
									} else {
										var msg = result.msg;
										alert(msg)
									}
								},
								error: function(Error) {
									console.log(Error);
								},
								complete: function(xhr, data) {
									console.log("complete");
								}
							});
					});
					$(function() {
					
						$('#workAddress').focus(function() {
							$('#beError').hide();
						});
					});
					/**
					 * 手机正则
					 */
					function checkPhone(phone){
						if(!(/^1(3|4|5|7|8)\d{9}$/.test(phone))){
							return false;
						}else{
							return true;
						}
					}
					//当省份的选择发生变化时调用 该方法   将市县加载到下拉选择框
					$("#provincem").change(function() {
						//1.获取省份选择框的对象
						var provincesobj = document.getElementById("provincem");
						//2.获取市县选择框的对象
						var cityobj = document.getElementById("city");
						//3.获取被选择的省份的索引
						var index = provincesobj.selectedIndex;

						//alert(provincesobj[index].value+","+provincesobj[index].text);
						////4.通过省份的索引获取它的value值，value值也是它在数组的索引值
						var value = provincesobj[index].value;
						//5.获取对应省份的市县数组
						var cityName = cityArr[value];
						//6.将下拉框清除索引为0之后的，只保留第一个
						cityobj.length = 1;
						//通过循环遍历市县元素给下拉框赋值
						for (var i = 1; i < cityArr[value].length; i++) {
							cityobj.options[cityobj.options.length] = new Option(cityName[i], i);

						}
					});
					//百度地图API功能
								var map = new BMap.Map("allmap");
								//控件添加
								map.addControl(new BMap.NavigationControl());
								map.addControl(new BMap.MapTypeControl());
								map.addControl(new BMap.ScaleControl());
								map.addControl(new BMap.OverviewMapControl());
					
								var point = new BMap.Point(116.331398, 39.897445); //初始化坐标点
								map.centerAndZoom(point, 15);
								/* map.centerAndZoom(, 15); */
								map.enableScrollWheelZoom(true); //允许缩放
								var gc = new BMap.Geocoder(); //地址定位
								var local = new BMap.LocalSearch(map, {
									renderOptions: {
										map: map
									}
								});
					
								function showInfo(e) {
									map.clearOverlays(); //清除所有覆盖物
									//map.centerAndZoom(new BMap.Point(olng, olat), 11);//重定义中心点
									//alert(e.point.lng + ", " + e.point.lat);
									var marker = new BMap.Marker(new BMap.Point(e.point.lng, e.point.lat)); // 创建标注
									marker.addEventListener("mouseup", function(em) { //覆盖物监听事件--释放鼠标时定位覆盖物位置
										var pt = em.point; //移动后重新定位
										gc.getLocation(pt, function(rs) {
											var addComp = rs.addressComponents;
											var label = new BMap.Label("我的坐标：" + em.point.lng + ", " + em.point.lat + "  我的地址：" + addComp.province +
												", " + addComp.city + ", " + addComp.district + ", " + addComp.street + ", " + addComp.streetNumber, {
													offset: new BMap.Size(20, -10)
												});
											// marker.setLabel(label);//新坐标-新地址
											if (rs) {
												var sContent =
													"&lt;h4 style='margin:0 0 5px 0;padding:0.2em 0'&gt;" + addComp.province + "&lt;/h4&gt;" +
													"&lt;p style='margin:0;line-height:1.5;font-size:13px;text-indent:2em'&gt;" + rs.address + "&lt;/p&gt;" +
													"&lt;/div&gt;";
												var infoWindow = new BMap.InfoWindow(sContent); // 创建信息窗口对象
												//图片加载完毕重绘infowindow
												marker.openInfoWindow(infoWindow);
											}
					
											$('#lat').val(em.point.lat);
											$('#lng').val(em.point.lng);
										});
									});
									marker.enableDragging(); //可拖拽
									map.addOverlay(marker); // 将标注添加到地图中
					
									/////////////////////地址定位
									var pt = e.point;
									gc.getLocation(pt, function(rs) {
										var addComp = rs.addressComponents;
										var label = new BMap.Label("我的坐标：" + e.point.lng + ", " + e.point.lat + "  我的地址：" + addComp.province + ", " +
											addComp.city + ", " + addComp.district + ", " + addComp.street + ", " + addComp.streetNumber, {
												offset: new BMap.Size(20, -10)
											});
										//marker.setLabel(label);
										if (rs) {
											var sContent =
												"&lt;h4 style='margin:0 0 5px 0;padding:0.2em 0'&gt;" + addComp.province + "&lt;/h4&gt;" +
												"&lt;p style='margin:0;line-height:1.5;font-size:13px;text-indent:2em'&gt;" + rs.address + "&lt;/p&gt;" +
												"&lt;/div&gt;";
											var infoWindow = new BMap.InfoWindow(sContent); // 创建信息窗口对象
											//图片加载完毕重绘infowindow
											marker.openInfoWindow(infoWindow);
										}
					
										$('#lat').val(e.point.lat);
										$('#lng').val(e.point.lng);
									});
					
									//////////////////////重置中心点
									olng = e.point.lng;
									olat = e.point.lat;
								}
								map.addEventListener("click", showInfo); //地图点击事件
					
								$(function() {
									$('#mapPreview').bind('click', function() {
										$.colorbox({
											inline: true,
											href: "#baiduMap",
											title: "公司地址"
										});
										var address = $('#positionAddress').val();
										var city = $('#workAddress').val();
										map.setCurrentCity(city);
										map.setZoom(15);
										gc.getPoint(address, function(point) {
											if (point) {
												map.centerAndZoom(point, 15);
												map.setZoom(15);
												map.setCenter(point);
												local.search(address);
											}
										}, city);
										/* map.addEventListener("tilesloaded",function(){
						map.setZoom(15);
					}); */
									});
								});
				</script>
				<!-- end old -->

				<div class="clear"></div>
				<input type="hidden" value="c29d4a7c35314180bf3be5eb3f00048f" id="resubmitToken">
				<a rel="nofollow" title="回到顶部" id="backtop" style="display: none;"></a>
			</div><!-- end #container -->
		</div><!-- end #body -->
		<div id="footer">
			<div class="wrapper">
				<a rel="nofollow" target="_blank" href="about.html">联系我们</a>
				<a target="_blank" href="http://www.lagou.com/af/zhaopin.html">互联网公司导航</a>
				<a rel="nofollow" target="_blank" href="http://e.weibo.com/lagou720">我们的微博</a>
				<a rel="nofollow" href="javascript:void(0)" class="footer_qr">我们的微信<i></i></a>
				<div class="copyright">&copy;2019-2020 qiuxinxin <a href="http://www.baidu.com"
					 target="_blank">东莞理工学院城市学院备14023790号-2</a></div>
			</div>
		</div>

		<script src="style/js/core.min.js" type="text/javascript"></script>
		<script src="style/js/popup.min.js" type="text/javascript"></script>

		<!--  -->


		<div id="cboxOverlay" style="display: none;"></div>
		<div id="colorbox" class="" role="dialog" tabindex="-1" style="display: none;">
			<div id="cboxWrapper">
				<div>
					<div id="cboxTopLeft" style="float: left;"></div>
					<div id="cboxTopCenter" style="float: left;"></div>
					<div id="cboxTopRight" style="float: left;"></div>
				</div>
				<div style="clear: left;">
					<div id="cboxMiddleLeft" style="float: left;"></div>
					<div id="cboxContent" style="float: left;">
						<div id="cboxTitle" style="float: left;"></div>
						<div id="cboxCurrent" style="float: left;"></div><button type="button" id="cboxPrevious"></button><button type="button"
						 id="cboxNext"></button><button id="cboxSlideshow"></button>
						<div id="cboxLoadingOverlay" style="float: left;"></div>
						<div id="cboxLoadingGraphic" style="float: left;"></div>
					</div>
					<div id="cboxMiddleRight" style="float: left;"></div>
				</div>
				<div style="clear: left;">
					<div id="cboxBottomLeft" style="float: left;"></div>
					<div id="cboxBottomCenter" style="float: left;"></div>
					<div id="cboxBottomRight" style="float: left;"></div>
				</div>
			</div>
			<div style="position: absolute; width: 9999px; visibility: hidden; display: none;"></div>
		</div>
	</body>
</html>
